<!-- 侧边栏 -->
<div class="page-content">
    <div class="block-title">
        <div class="width-100 ">
            <a class="reader-personal margin-bottom" href="/user.html"><img class=" avatar"
                    src="/images/headimage/2.jpg" alt="" />
                <div class="content">
                    <p id="loginName"></p>
                    <p class="text-color-gray font-size-12"> 未开通 </p>
                    <p id="bookCoin">剩余书币：</p>
                </div>
            </a>
            <a class="button button-round button-fill button-small" href="/login.html">切换账号</a>
        </div>
    </div>
    <div class="list">
        <ul>
            <li class=""><a class="item-link panel-close" href="/index.html">
                    <div class="item-content">
                        <div class="item-media">
                            <i class="icon material-icons">home</i>
                        </div>
                        <div class="item-inner">
                            <div class="item-title">
                                首页
                            </div>
                        </div>
                    </div>
                </a></li>
            <li class=""><a class="item-link panel-close" href="/cate.html">
                    <div class="item-content">
                        <div class="item-media">
                            <i class="icon material-icons">widgets</i>
                        </div>
                        <div class="item-inner">
                            <div class="item-title">
                                分类
                            </div>
                        </div>
                    </div>
                </a></li>
            <li class=""><a class="item-link panel-close" href="/top.html">
                    <div class="item-content">
                        <div class="item-media">
                            <i class="icon material-icons">equalizer</i>
                        </div>
                        <div class="item-inner">
                            <div class="item-title">
                                排行
                            </div>
                        </div>
                    </div>
                </a></li>
            <li class=""><a class="item-link panel-close" href="/favorite.html">
                    <div class="item-content">
                        <div class="item-media">
                            <i class="icon material-icons">local_library</i>
                        </div>
                        <div class="item-inner">
                            <div class="item-title">
                                书架
                            </div>
                        </div>
                    </div>
                </a></li>
        </ul>
    </div>
</div>
<!-- 侧边栏 -->
<script type="text/javascript">
$(function () {
    var imgpath = '';
    if(localStorage.getItem("authToken")){
        appCenter.doHeaderPost(baseApi + "/carton/app/user",{ },{'authToken':localStorage.getItem("authToken")},function (data) {
            if (data.code === 0) {
                $("#loginName").html(data.data.loginName);
                $("#bookCoin").html("剩余书币："+data.data.bookCoin);
                $(".avatar").attr("src",data.data.avatar);
                appCenter.userId=data.data.userId;
                appCenter.bookCoin = data.data.bookCoin;
            }
        })
    }
});
</script>
